package com.logAndSignProvider;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
import org.springframework.context.annotation.Bean;
import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;
import util.JWTUtil;

/**
 * The type Log and sign provider application.
 */
@SpringBootApplication
@EnableDiscoveryClient
public class LogAndSignProviderApplication {
    /**
     * Encoder b crypt password encoder.
     *
     * @return the b crypt password encoder
     */
    @Bean
    public BCryptPasswordEncoder encoder() {
        return new BCryptPasswordEncoder();
    }

    /**
     * Jwt util jwt util.
     *
     * @return the jwt util
     */
    @Bean
    public JWTUtil jwtUtil() {
        return new JWTUtil();
    }

    /**
     * The entry point of application.
     *
     * @param args the input arguments
     */
    public static void main(String[] args) {
        SpringApplication.run(LogAndSignProviderApplication.class, args);
    }
}
